package com.moyun.finance.repository;

import com.moyun.finance.entity.Contract;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;

import java.util.List;

public interface ContractRepository extends JpaRepository<Contract,String>, JpaSpecificationExecutor<Contract> {
    List<Contract> findByCompanyId(String companyId);
    List<Contract> findByCompanyIdAndContractType(String companyId, int type);
    List<Contract> findByCompanyIdAndContractTypeAndAllTypeId(String companyId, int type, String allTypeId);
}
